<html xmlns:th="http://www.thymeleaf.org">
<html>
  <head>
    <base href="<%=basePath%>">
	  <meta charset="UTF-8">
    <title>发送短信</title>
	<meta name="pragma" content="no-cache">
	<meta name="cache-control" content="no-cache">
	<meta name="expires" content="0">
	  <link href="../../../../static/easyui/themes/insdep/easyui.css" rel="stylesheet" type="text/css">
	  <link href="../../../../static/easyui/themes/insdep/easyui_animation.css" rel="stylesheet" type="text/css">
	  <link href="../../../../static/easyui/themes/insdep/easyui_plus.css" rel="stylesheet" type="text/css">
	  <link href="../../../../static/easyui/themes/insdep/insdep_theme_default.css" rel="stylesheet" type="text/css">
	  <link href="../../../../static/easyui/themes/insdep/icon.css" rel="stylesheet" type="text/css">
	  <link href="../../../../static/easyui/themes/color.css" rel="stylesheet" type="text/css">
	  <link href="../../../../static/ztree/zTreeStyle/zTreeStyle.css" rel="stylesheet" type="text/css" >
	  <link href="../../../../static/css/common.css" rel="stylesheet" type="text/css" >
	  <script type="text/javascript" src="../../../../static/jquery/jquery.min.js"></script>
	  <script type="text/javascript" src="../../../../static/easyui/jquery.easyui.min.js"></script>
	  <script type="text/javascript" src="../../../../static/easyui/themes/insdep/jquery.insdep-extend.min.js"></script>
	  <script type="text/javascript" src="../../../../static/ztree/jquery.ztree.all.min.js"></script>
	  <script type="text/javascript" src="../../../../static/easyui/easyui-lang-zh_CN.js"></script>
	  <script type="text/javascript" src="../../../../static/kindeditor/kindeditor-all-min.js"></script>
	
	
  </head>
  <body style="width:100%;max-width:500px;padding:30px 60px;">
	<section class="info-section">
		<form id="form" method="post">
			<table>
				<!--<tr>
					<td class="text-title">接收人姓名：</td>
					<td class="text-content">
						<input type="text"
							class="easyui-textbox theme-textbox-radius" data-options="required:true,validType:'length[2,50]'">
					</td>
				</tr>-->
				<tr>
					<td class="text-title">接收人电话：</td>
					<td class="text-content">
						<input type="text" name="telephone" data-options="required:true" class="easyui-textbox theme-textbox-radius">
					</td>
				</tr>
				  <tr>
					<td class="text-title">信息正文：</td>
					<td class="text-content">
						<textarea id="content" name="content" rows="5"  cols="20"></textarea></td>
				</tr>
				<tr>
					<td colspan="2" style="text-align: center;margin-top: 10px;">
						<a href="javascript:void(0);" id="sendBtn" class="easyui-linkbutton button-primary">发送</a>
						<a href="javascript:void(0);" id="resetBtn" class="easyui-linkbutton button-danger">重置</a>
					</td>
				</tr>
			</table>
		</form>
	</section>
	<script type="text/javascript">
		
        //为发送按钮绑定单击事件
        $("#sendBtn").on("click",function(){
        	//在提交之前调用编辑器的同步方法，这样才能获取到textarea中的内容
        	// editor.sync();
        	$("#form").form("submit",{
        		url : "/manage/marketing/MarketingAction_sendMsg.do",
        		onSubmit : function(){
        			return $("#form").form("validate");
        		},
        		
        		success : function(data){
        			if(data){
        				var json = eval("("+data+")");
        				if(json.success){
        					$.messager.alert("提示","信息发送成功",);
        					return true;
        				}
        			}
        			$.messager.alert("警告","信息发送失败");
        		}

        	});
        });
       
	</script>
	<script type="text/javascript">
	 $(function() {
			//重置按钮
			$("#resetBtn").on("click",function(event){
				$("#form").form("reset");
			});
			})
	</script>
</body>
</html>